﻿<%@ Page Title="Change Password" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true"
    CodeBehind="ChangePassword.aspx.cs" Inherits="Chinesys.UI.Account.ChangePassword" %>

<%@ MasterType VirtualPath="~/Site.Master" %>
<%@ Register Src="../Controls/ValidationSummary.ascx" TagName="ValidationSummary"
    TagPrefix="uc1" %>
<asp:Content ID="HeaderContent" runat="server" ContentPlaceHolderID="HeadContent">
    <link type="text/css" rel="Stylesheet" href="../Styles/CustomStyles.css" />
</asp:Content>
<asp:Content ID="BodyContent" runat="server" ContentPlaceHolderID="MainContent">
    <script type="text/javascript">
        $(document).ready(function () {

            if ($('#hdnBizRulesException').val().length > 0) {
                var text = $('#hdnBizRulesException').val();
                $('#hdnBizRulesException').val('');
                $('#modalText').text(text);

                $("#modal").overlay({
                    top: 260,
                    mask: {
                        color: '#fff',
                        loadSpeed: 200,
                        opacity: 0.5
                    },
                    closeOnClick: false,
                    load: true
                });
            }
        });
    </script>
    <h2>
        Cambiar Password
    </h2>
    <p>
        Use el formulario siguiente para cambiar su password.
    </p>
    <span class="failureNotification">
        <asp:Literal ID="FailureText" runat="server"></asp:Literal>
    </span>
    <asp:ValidationSummary ID="ChangeUserPasswordValidationSummary" runat="server" CssClass="failureNotification"
        ValidationGroup="ChangeUserPasswordValidationGroup" />
    <uc1:ValidationSummary ID="validationSummary" runat="server" />
    <asp:HiddenField ID="hdnBizRulesException" runat="server" ClientIDMode="Static" />
    <div id="modal">
        <div>
            <h2>
                Mensaje del Sistema</h2>
            <p id="modalText">
            </p>
            <button class="close">
                Cerrar
            </button>
        </div>
    </div>
    <div class="accountInfo">
        <fieldset class="changePassword">
            <legend>Informacíon de Usuario</legend>
            <p>
                <asp:Label ID="CurrentPasswordLabel" runat="server" AssociatedControlID="CurrentPassword">Password Anterior:</asp:Label>
                <asp:TextBox ID="CurrentPassword" runat="server" CssClass="passwordEntry" TextMode="Password"></asp:TextBox>
            </p>
            <p>
                <asp:Label ID="NewPasswordLabel" runat="server" AssociatedControlID="NewPassword">Nuevo Password:</asp:Label>
                <asp:TextBox ID="NewPassword" runat="server" CssClass="passwordEntry" TextMode="Password"></asp:TextBox>
            </p>
            <p>
                <asp:Label ID="ConfirmNewPasswordLabel" runat="server" AssociatedControlID="ConfirmNewPassword">Confirme Nuevo Password:</asp:Label>
                <asp:TextBox ID="ConfirmNewPassword" runat="server" CssClass="passwordEntry" TextMode="Password"></asp:TextBox>                
            </p>
        </fieldset>
        <p class="submitButton">
            <asp:Button ID="ChangePasswordPushButton" runat="server" CommandName="ChangePassword"
                Text="Cambiar Password" ValidationGroup="ChangeUserPasswordValidationGroup" OnClick="ChangePasswordPushButton_Click" />
        </p>
    </div>
</asp:Content>
